﻿@page
@model FytSoa.Web.Pages.Bbs.ExpertModel
@{
    Layout = "_Layout";
    ViewData["Title"] = "专家";
}
<div class="col-md-8 main-content">
    <div class="row select-category">
        <div class="col-md-6 col-xs-6 current-category">
            <span>专家</span>
        </div>
        <div class="col-md-6 col-xs-6 select-categories input-find-tags">
            <form class="form-input-search" autocomplete="off" method="GET" action="/bbs/expert/">
                <input autocomplete="off" type="text" name="key" value="" class="search-users" placeholder="Find Users" />
                <i class="fa fa-chevron-circle-right"></i>
            </form>
        </div>
    </div>
    <!-- END SELECT-CATEGORY -->
    <div class="row question-filter">
        <div class="col-md-6 col-xs-6 sort-questions">
            <ul>
                <li>
                    <a class="@(Model.Types==1?"active":"")" href="/bbs/expert/">专家</a>
                </li>
                <li>
                    <a class="@(Model.Types==0?"active":"")" href="/bbs/expert/?type=0">最新加入</a>
                </li>
            </ul>
        </div>
    </div>
    <!-- END QUESTIONS-FILTER -->
    <div class="main-user-list">
        <ul id="main_users_list" class="row">
            @{
                if (Model.UserList!=null)
                {
                    foreach (var item in Model.UserList.Items)
                    {
                        <li class="user-item col-md-4 col-xs-6">
                            <span class="user-avatar">
                                <img itemprop="image" src="@item.HeadPic" class="avatar" alt=""/>
                            </span>
                            <div class="left-info">
                                <a href="/bbs/user/@item.Guid"><span class="display_name">@item.NickName</span></a><br>
                                <span class="location">
                                    <i class="fa fa-map-marker"></i> @(item.AnswerCount)个答案 @(item.AdoptCount)次被采纳
                                </span>
                                <div class="question-cat">
                                    加入时间：@(FytSoa.Common.Utils.DateDiff(item.AddTime,DateTime.Now))
                                </div>
                            </div>
                        </li>
                    }
                }
            }
        </ul>
    </div>
    <!-- END MAIN-QUESTIONS-LIST -->
    <div class="clearfix grey-line"></div>
    <div class="row paginations home">
        <div class="col-md-12">
            <ul class='page-numbers'>
                @Html.Raw(PageHelper.HtmlsBBs(Model.pageIndex, 5, Model.UserList?.TotalPages ?? 0, "/bbs/expert/"))
            </ul>
        </div>
    </div>
    <!-- END MAIN-PAGINATIONS -->
</div>